<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>vue中的条件</title>
  <script src="../static/vue.js"></script>
</head>
<body>
<div id="app">
  <div v-if="show"> {{message}}</div>
  <div v-else-if="show"> {{message}}</div>
  <div v-else="show"> {{message}}</div>
  <div v-show="show">{{message}}</div>
  <div v-if="show">
    用户名 <input type="text" key="userName">
  </div>
  <div v-else>
    邮箱:<input type="text" aria-keyshortcuts="email">
  </div>
</div>

<script>
  var vm = new Vue({
    el: '#app',
    data: {
      show: true,
      message: 'hello world'
    }
  })
</script>
</body>
</html>
